<template>
  <div>
    <iframe v-bind:src="iframeUrlComputed"></iframe>
  </div>
</template>

<script>
export default {
  computed: {
    iframeUrlComputed() {
      return this.$store.state.permission.outUrl
    }
  },
  watch: {
    $route: {
      handler(to) {
        this.$store.commit("permission/CHANGE_OUTURL", to.meta.url)
      },
      immediate: true,
      deep: true
    }
  }
}
</script>

<style lang="scss" scoped>
iframe {
  border: none;
  width: calc(100vw - #{$sideBarWidth} - 30px);
  height: calc(100vh - #{$navbarHeight} - #{$tagsviewHeight} - 40px);
  margin: 0;
}
</style>
